<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>打印单据</title>
    <link type="text/css" rel="stylesheet" href="../../dist/css/global.css"/>
    <script type="text/javascript" src="../../plugins/jQuery/jquery-2.2.3.min.js"></script>
    <script type="text/javascript" src="../../plugins/underscore/underscore.js"></script>
    <script>
        var url = window.location.href
            , start = url.indexOf("?") == -1 ? null : url.indexOf("?") + 1
            , end = url.indexOf("#")
            , param
            , params = {};
        if (end == -1) {
            param = url.slice(start);
        } else {
            param = url.slice(start, end);
        }
        if (param.search('=') > -1) {
            param = param.split("&");
            $.each(param, function (i, j) {
                params[j.split('=')[0]] = decodeURIComponent(j.split('=')[1]);
            });
        }
    </script>
</head>
<body>
<div class="printWrap" id="printWrap">
    <script type="text/template">
        <h2>财务支出审批单</h2>
        <ul>
            <li>入库单号：<%=data.p1%></li>
            <li>日期：<%=data.p1%>年<%=data.p2%>月<%=data.p3%>日</li>
        </ul>
        <table style="width: 100%" cellpadding="0" cellspacing="0">
            <tr>
                <td>申请部门</td>
                <td colspan="2"><%=data.p1%></td>
                <td>申请人</td>
                <td colspan="2"><%=data.p1%></td>
                <td>主管副总审批</td>
                <td colspan="2"><%=data.p1%></td>
            </tr>
            <tr>
                <td rowspan="3"><%=data.p1%></td>
                <td colspan="8"><%=data.p1%></td>
            </tr>
            <tr>
                <td colspan="8"><%=data.p1%></td>
            </tr>
            <tr>
                <td colspan="8"><%=data.p1%></td>
            </tr>
            <tr>
                <td>预计金额</td>
                <td colspan="4"><%=data.p1%></td>
                <td>实际结算金额</td>
                <td colspan="3"><%=data.p1%></td>
            </tr>
            <tr>
                <td>付款方式</td>
                <td colspan="2"><%=data.p1%></td>
                <td>总经理签字</td>
                <td colspan="2"></td>
                <td>财务负责人签字</td>
                <td colspan="2"></td>
            </tr>
            <tr>
                <td>记账确认</td>
                <td colspan="3" class=" nbr"></td>
                <td class="nbl nbr"><input type="checkbox" checked/> 已记账</td>
                <td class="nbl nbr">记账人</td>
                <td colspan="3" class="nbl"></td>
            </tr>
        </table>
    </script>
</div>
<script>
    $(function () {
        $.ajax({
            url:"../../simdata/common_modify_action.json",
            data:{},
            success:function (data) {
                $("#printWrap").html(function () {
                    return _.template($(this).children("script").html())({
                        data:data
                    })
                })
            }
        })

    })
</script>
</body>
</html>

